package com.xunce.xcworkservice.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.v3.oas.annotations.media.Schema;

import java.time.LocalDateTime;

import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

/**
 * @ClassName:  AccountVerify  
 * @Author:     yanlong.guo      
 * @Date:       2023/12/19 15:15   
 */

@Schema(description="审核人表")
@Data
@TableName(value = "account_verify")
public class AccountVerify {
    @TableId(value = "id", type = IdType.AUTO)
    @Schema(description="主键，工时单ID，唯一标识")
    private Integer id;

    @TableField(value = "account_id")
    @Schema(description="审核人,account表中的主键")
    @NotNull(message = "员工不能为空")
    private Integer accountId;

    @TableField(exist = false)
    @Schema(description="审核人名称")
    private String accountName;

    @TableField(value = "departments")
    @Schema(description="审核组别")
    @NotEmpty(message = "审核组别不能为空")
    private String departments;

    @TableField(value = "verify_type")
    @Schema(description="审核方式：0-同级审核")
    private Integer verifyType;

    @TableField(value = "next_account_id")
    @Schema(description="下一步审核人,account表中的主键")
    private Integer nextAccountId;

    @TableField(value = "created_at", fill = FieldFill.INSERT)
    @Schema(description="创建时间")
    private LocalDateTime createdAt;

    @TableField(value = "updated_at", fill = FieldFill.INSERT_UPDATE)
    @Schema(description="修改时间")
    private LocalDateTime updatedAt;

    @TableField(exist = false)
    @Schema(description = "部门名称")
    private String departmentNames;
}